<%@ page import="com.wilmar.designer.service.DocumentService" %>
<%@ page import="org.phprpc.PHPRPC_Server" %>
<%@ page import="org.springframework.context.ApplicationContext" %>
<%@ page import="org.springframework.web.context.support.WebApplicationContextUtils" %>
<%@ page import="com.wilmar.process.entity.User" %>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%
    PHPRPC_Server phprpc_server = new PHPRPC_Server();
    ApplicationContext applicationContext = WebApplicationContextUtils.getWebApplicationContext(application);
    DocumentService documentService = (DocumentService) applicationContext.getBean("documentService");
    documentService.setUser((User) session.getAttribute("currentuser"));
    phprpc_server.add(documentService);
    phprpc_server.start(request, response);
%>